#pragma once

#include "LvWindow.h"
#include "LvDevice.hpp"
#include "LvGameObject.h"
#include "LvRenderer.h"
#include "SimpleRenderSystem.h"

#define GLM_FORCE_RADIANS
#define GLM_FORCE_DEPTH_ZERO_TO_ONE
#include <glm/glm.hpp>


#include <memory>
#include <vector>


struct SimplePushConstantData
{
	glm::mat2 transform{1.0f};
	glm::vec2 offset{};
	alignas(16) glm::vec3 color{};
};

class TriangleApp
{
public:
	static constexpr int WIDTH = 800;
	static constexpr int HEIGHT = 600;

	TriangleApp();
	~TriangleApp();

	TriangleApp(const TriangleApp&) = delete;
	TriangleApp& operator=(const TriangleApp&) = delete;

	void run();

private:
	void loadGameObjects();

	LvWindow lvWindow{ WIDTH, HEIGHT, "Hello Vulkan Triangle" };
	LvDevice lvDevice{ lvWindow };
	LvRenderer lvRenderer{ lvWindow, lvDevice };

	std::vector<LvGameObject> gameObjects;
};

